<% if( !@RoleUtils.hasCurrentUserRole('user') ) { %>
<li>
	<a href="javascript:" id="btnOnline" data-href="${ctx}/sys/online/list" data-title="${text('在线人员')}" title="${text('在线人员')}"
		class="${hasPermi('sys:online:view') ? 'addTabPage' : ''} " data-placement="bottom" data-container="body">
		<i class="icon-people"></i><span id="onlineCount" class="label label-success">0</span>
	</a>
	<script>
		function refreshOnlineCount(){
			$.get('${ctx}/sys/online/count?__notUpdateSession=true&__t='
					+ new Date().getTime(), function(data){
				try{$('#onlineCount').html(Number(data))}catch(e){}
			})
		}
		refreshOnlineCount(); // 先执行一次
		setInterval(refreshOnlineCount, 180000); // 3分钟执行一次
		$(function(){$('#btnOnline').tooltip()});
	</script>
</li>
<li>
	<a href="javascript:" id="btnMessageCount" data-href="${ctx}/message/message/goMessageList" data-title="${text('消息通知')}" title="${text('消息通知')}"
	   class="addTabPage" data-layer="true" data-layer-width="500" data-layer-height="300" data-placement="bottom" data-container="body">
		<i class="fa fa-commenting-o"></i><span id="messageCount" class="label label-success">0</span></a>
	<script>
		function refreshMessageCount(){
			$.get('${ctx}/message/message/findMessageCount', function(data){
				try{$('#messageCount').html(Number(data.allCount))}catch(e){}
			})
		}
		refreshMessageCount(); // 先执行一次
		setInterval(refreshMessageCount, 180000); // 3分钟执行一次
		$(function(){$('#btnMessageCount').tooltip()});
	</script>
</li>
<% } %>